#!/bin/bash
log_path=/var/log/apps/$app_name

if [ ! -d $log_path ];then
	mkdir -pv $log_path
fi
java -Xmx$max -Xms$min -XX:+UseParallelGC -XX:+UseParallelOldGC -XX:+PrintGCDetails  -XX:+PrintGCTimeStamps -XX:+UseGCLogFileRotation  -XX:GCLogFileSize=128M  -XX:NumberOfGCLogFiles=1  -Xloggc:${log_path} -XX:HeapDumpPath=${log_path} -XX:+HeapDumpOnOutOfMemoryError  -XX:ErrorFile=${log_path}/hs_err_%p.log  -Dfile.encoding=UTF-8   -jar /opt/app.jar
